I use PSpad as text editor to develop and debug my dxl code. In PSpad I use Ctrl-F9 to execute my code file within the DOORS execution environment of dxl language. Unfortunatelly only first 2000 characters of the file are sent and compiled for exucution. In PSpad there is no limit. It call the execution environment and send a file as parametrer. Is there a way to overcome this limitation.
Marc-Alain Simard
Marc-Alain - Thu Jul 23 16:21:29 EDT 2009 |
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? llandale - Fri Jul 24 10:59:06 EDT 2009
I just ran a 3500 line 131kb file in the DXL editor.
I guess I'm ignorant, but I have trouble using an editor (Crimson) to run the DXL. I just use the editor for syntax checking etc, fire up the DXL editor in the context I want, and issue an #include statement to run the DXL. Errors go to the clumsy DXL output pain ..err.. pane, oh well.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? SystemAdmin - Wed Jul 29 14:38:47 EDT 2009 llandale - Fri Jul 24 10:59:06 EDT 2009
I just ran a 3500 line 131kb file in the DXL editor.
I guess I'm ignorant, but I have trouble using an editor (Crimson) to run the DXL. I just use the editor for syntax checking etc, fire up the DXL editor in the context I want, and issue an #include statement to run the DXL. Errors go to the clumsy DXL output pain ..err.. pane, oh well.
Configure pspad such that it sends a #include<FileName> to DOORS instead of all the code. Must admit that I have the f9 key send the #include to the clipboard then paste it into the dxl window - doing it your way seemed to be unreliable, but maybe I was being thick.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? gpolley - Mon Aug 03 08:44:34 EDT 2009
Hi all,
I have never heard of setting up PSpad to invoke and debug DXL!
Please tell me more....! How is this done?
Thanks
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? SystemAdmin - Mon Aug 17 07:11:53 EDT 2009
I am also curious how you are executing the code from an external editor within the "execution environment of dxl language".
Please share your experience!
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? SystemAdmin - Wed Aug 19 08:43:40 EDT 2009 SystemAdmin - Mon Aug 17 07:11:53 EDT 2009
I am also curious how you are executing the code from an external editor within the "execution environment of dxl language".
Please share your experience!
Did some testing with Crimson Editor User Tools. If you create a new tool (Tools / Preferences) to startup DOORS (bin\doors.exe) with the argument of -u Username -P Password -dxl "#include <$FilePath>" then a new instance of DOORS is started, logged in (if you give your Username and Password as arguments) and the included script is then started in DOORS.
Of course this will not work with scripts depending on current Module, as there is no current Module, you have to load up modules to work with them.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? djakad - Wed Aug 19 09:51:25 EDT 2009
Just another method which I use for developing DXL....
I use the -a and -J command-line switches to add my own addins menus to the main DOORS window and Module windows. Within these addin menus, I include a few "dummy" or "blank" .dxl files. Then, any time I want to edit/create a DXL script, I just fire up any text editor and edit one of these files. Then just save your edits from within your editor, then run the DXL script from the menu within DOORS. You can even include keyboard shortcuts in the menu index files (.idx). I often assign Ctrl+1, Ctrl+2, Ctrl+3, etc., to several scripts which makes them quick and easy to run from any context.
You can either include the -a and -J switches in your Windows shortcut, or you can write a short Windows batch file (.bat) which launches DOORS and includes these switches.
With this method of developing DXL scripts, you don't need to use the built-in DOORS DXL editor. Not to mention, if some DOORS administor has locked down your "edit DXL privlidges", this method gets around that... you can always use the command-line switches and run your own DXL scripts this way.
You can find more about these command-line switches in the "Using DOORS (8.2)" manual, page 379. And for addin menus see "DXL Reference Manual (8.3)", page 597.
You can also include your own directory of Layout DXL files with the -L switch.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? llandale - Wed Aug 19 13:39:20 EDT 2009 SystemAdmin - Wed Aug 19 08:43:40 EDT 2009
Did some testing with Crimson Editor User Tools. If you create a new tool (Tools / Preferences) to startup DOORS (bin\doors.exe) with the argument of -u Username -P Password -dxl "#include <$FilePath>" then a new instance of DOORS is started, logged in (if you give your Username and Password as arguments) and the included script is then started in DOORS.
Of course this will not work with scripts depending on current Module, as there is no current Module, you have to load up modules to work with them.
Just about all my scripts depend on the context. I suppose you could code into the script setting the current folder and opening a module and setting it current, and possibly setting a particular object current, but sheesh, that takes a while and you end up with extra DOORS sessions.
Perhaps if the new tool could use VBA to communicate with an existing DOORS session, you would have something useful; except for regularly closing the DXL box to refresh the errors and print statements.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Marc-Alain - Thu Dec 03 18:34:18 EST 2009
Thany Mr. djakad and Mr. Goodman for your answer. It has worked, however I am now using "Eclipse DXL Editor" from SODIUS (see dxleditor.com). This is a good product and my life is relativelly better, althought i have some difficulty to define the scope (the current item).
Marc-Alain Simard
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Mathias Mamsch - Sun Dec 06 07:27:02 EST 2009 Marc-Alain - Thu Dec 03 18:34:18 EST 2009
Thany Mr. djakad and Mr. Goodman for your answer. It has worked, however I am now using "Eclipse DXL Editor" from SODIUS (see dxleditor.com). This is a good product and my life is relativelly better, althought i have some difficulty to define the scope (the current item).
Marc-Alain Simard
I am going to post my version of a "Run DXL" script here, which has the following features:
-
it will run your dxl file in the current context, i.e. your currently open DOORS session (using the COM runStr Method of DOORS application)
-
if you have exactly one module open it will take set this one as a "current module"
-
if you have more than one module open it will ask you which one to use as "current module" after the start of the DXL program
-
after the run is finished it will read the output of the DXL program from the Run DXL Window and print it to the standard output (using the included showdoors.exe)
it is run using:
cscript.exe /nologo <SCRIPT_PATH>\dxl_run_script.vbs <DXL FILE>
So you can include this command in your favourite DXL editor. As much as I like the "DXL Editor", it has some annoying features which prevent me to switch yet.
Have fun with it.
Regards, Mathias
PS.: The source for the showdoors.exe is included, it is written in MASM to have a small and handy executable.
Attachments
attachment_14414275_RunDOORS.zip
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Irfan_Jamal - Tue Jan 05 01:22:25 EST 2010 Mathias Mamsch - Sun Dec 06 07:27:02 EST 2009
I am going to post my version of a "Run DXL" script here, which has the following features:
-
it will run your dxl file in the current context, i.e. your currently open DOORS session (using the COM runStr Method of DOORS application)
-
if you have exactly one module open it will take set this one as a "current module"
-
if you have more than one module open it will ask you which one to use as "current module" after the start of the DXL program
-
after the run is finished it will read the output of the DXL program from the Run DXL Window and print it to the standard output (using the included showdoors.exe)
it is run using:
cscript.exe /nologo <SCRIPT_PATH>\dxl_run_script.vbs <DXL FILE>
So you can include this command in your favourite DXL editor. As much as I like the "DXL Editor", it has some annoying features which prevent me to switch yet.
Have fun with it.
Regards, Mathias
PS.: The source for the showdoors.exe is included, it is written in MASM to have a small and handy executable.
Hello Mathias,
This is a great work!
Can I find out the current instance of DOORS (if any) using JAVA also? If so, can you please help me in modifying your code to achieve this?
Thanks & Regards
Irfan
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Mathias Mamsch - Tue Jan 05 14:05:57 EST 2010 Irfan_Jamal - Tue Jan 05 01:22:25 EST 2010
Hello Mathias,
This is a great work!
Can I find out the current instance of DOORS (if any) using JAVA also? If so, can you please help me in modifying your code to achieve this?
Thanks & Regards
Irfan
I don't know if java supports calling OLE objects natively, since I am not a big java programmer. I think you need an extra library for this, like com4j or something (see https://com4j.dev.java.net/tutorial.html). Then you can translate the COM calls in the vbs file into appropriate java calls. For the windows api part (e.g. finding the DOORS DXL window, reading the output, etc.) you need to call functions from the native windows DLLs (user32.dll). But the details of this accomplishing this task probably belong to a JAVA forum.
Why do you need java for this? Do you want to integrate the functionality into another program? Which functionality exactly?
Regards, Mathias
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Irfan_Jamal - Tue Jan 05 22:11:10 EST 2010 Mathias Mamsch - Tue Jan 05 14:05:57 EST 2010
I don't know if java supports calling OLE objects natively, since I am not a big java programmer. I think you need an extra library for this, like com4j or something (see https://com4j.dev.java.net/tutorial.html). Then you can translate the COM calls in the vbs file into appropriate java calls. For the windows api part (e.g. finding the DOORS DXL window, reading the output, etc.) you need to call functions from the native windows DLLs (user32.dll). But the details of this accomplishing this task probably belong to a JAVA forum.
Why do you need java for this? Do you want to integrate the functionality into another program? Which functionality exactly?
Regards, Mathias
Hello Mathias,
Thanks for your reply.
I am trying to build a GUI in JAVA which will be started from a DOORS Module. All the input collected from this GUI should be saved back to this DOORS module. So I thought I could do that using your idea of running a DXL script on the current instance of DOORS so that the data is saved back to the module.
We have a complex GUI which cannot be built using DXL :-(
Regards
Irfan
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Mathias Mamsch - Wed Jan 06 07:04:32 EST 2010 Irfan_Jamal - Tue Jan 05 22:11:10 EST 2010
Hello Mathias,
Thanks for your reply.
I am trying to build a GUI in JAVA which will be started from a DOORS Module. All the input collected from this GUI should be saved back to this DOORS module. So I thought I could do that using your idea of running a DXL script on the current instance of DOORS so that the data is saved back to the module.
We have a complex GUI which cannot be built using DXL :-(
Regards
Irfan
So then the task will be easier, you don't have to worry about finding the DOORS window etc. You just use the COM calls from the DXL scripts. Take a look at the com4j library and at the "Automation Client Support" chapter in the DXL help. Regards, Mathias
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Irfan_Jamal - Thu Jan 07 04:51:17 EST 2010 Mathias Mamsch - Wed Jan 06 07:04:32 EST 2010
So then the task will be easier, you don't have to worry about finding the DOORS window etc. You just use the COM calls from the DXL scripts. Take a look at the com4j library and at the "Automation Client Support" chapter in the DXL help. Regards, Mathias
Hi Mathias,
I guess it is not simple and should not be done using DXL.
When my JAVA GUI opens, it has no link to DOORS. So, for any updations on the DOORS module, it (JAVA) should find the running DOORS instance first and then execute any DXL on that.
Regards
Irfan
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? EHcnck - Tue Sep 16 13:47:53 EDT 2014 Mathias Mamsch - Sun Dec 06 07:27:02 EST 2009
I am going to post my version of a "Run DXL" script here, which has the following features:
-
it will run your dxl file in the current context, i.e. your currently open DOORS session (using the COM runStr Method of DOORS application)
-
if you have exactly one module open it will take set this one as a "current module"
-
if you have more than one module open it will ask you which one to use as "current module" after the start of the DXL program
-
after the run is finished it will read the output of the DXL program from the Run DXL Window and print it to the standard output (using the included showdoors.exe)
it is run using:
cscript.exe /nologo <SCRIPT_PATH>\dxl_run_script.vbs <DXL FILE>
So you can include this command in your favourite DXL editor. As much as I like the "DXL Editor", it has some annoying features which prevent me to switch yet.
Have fun with it.
Regards, Mathias
PS.: The source for the showdoors.exe is included, it is written in MASM to have a small and handy executable.
Hello,
Can you attach the files again. I'm unable to unzip the attachment. Thank you.
|
|
Re: How to overcome the 2000 characters limit of Doors DXL editor? Wolfgang Uhr - Wed Sep 17 03:30:54 EDT 2014 EHcnck - Tue Sep 16 13:47:53 EDT 2014
Hello,
Can you attach the files again. I'm unable to unzip the attachment. Thank you.
Take this editor http://sodius.com/. There is a free version and If you realy develop dxl scripts you should by the Pro-Version ...
|
|